<script type="text/javascript" >
<{include file='user/position/js/index.js'}>
</script>
<style type="text/css">
    .button {
        background: url(/images/left-menu-li.gif) repeat-x left top #F1F6F9;
        border: 1px solid #318DAC;
        font-weight: bold;
        padding: 2px 5px;
        font-weight: lighter;
        color: #318DAC;
        vertical-align: middle;
        -moz-border-radius: 3px;
        -webkit-border-radius: 3px;
        margin: auto 5px
    }

    div#add {
        text-align: center;
    }

    div.info {
        text-align: left;
    }

    div.item {
        margin-bottom: 12px;
    }

    input.text {
        height: 22px;
        margin-left: 8px;
    }

    span.text {
        margin-left: 8px;
    }

    span.userInfoLeft {
        float: left;
        text-align: right;
        width: 100px;
    }

    span.userInfoRight {
        float: left;
    }

    div.errormsg {
        color: red;
        float: right;
        padding-left: 3px;
        text-align: left;
    }

    .validateTips {
        background-color: #FFFECD;
        border: 1px solid #CCCCCC;
        color: #FF0000;
        display: none;
        line-height: 26px;
        min-height: 26px;
        margin-bottom: 5px;
        text-align: center;
        height: auto;
        overflow: hidden;
    }

    .validateTips span {
        float: left;
        clear: both;
        line-height: 24px;
        width: 100%;
    }
</style>

<div id="right_confirm" style="display: none;">
    <p style="text-align:center;font-size: 14px;color: red;font-weight: bold;">
        <{$lang.ok}>要<{$lang.delete}>吗？
    </p>
</div>

<div id="iTitle">
    <div id="iTitleSub">

        <form id="sForm" name="sForm" onkeypress="if(event.keyCode==13){return false;}">
            <div>
                <label>
                    <{$lang.position}><{$lang.name}>：<input id="position_name" class="myInput" onkeyup="if(event.keyCode==13){search();}" type="text" name="position_name">
                </label>&nbsp;
                <input class="button" type="button" value="<{$lang.search}>" onclick="search();">&nbsp;&nbsp;
                <input class="button" type="button" value="<{$lang.add}>" id="addButton" onclick="editPosition('')">&nbsp;&nbsp;
            </div>
        </form>

    </div>
    <div id="message" style="color:red;"></div>
    <div class="myClear"></div>
</div><!-- id="iTitle" 结束 -->

<h3><{$lang.position}><{$lang.list}></h3>

<table width="100%" border="0" cellspacing="0" cellpadding="0" class="myTab">
    <thead>
    <tr>
        <th>ID</th>
        <th><{$lang.position}><{$lang.name}></th>
        <th><{$lang.department}><{$lang.name}></th>
        <th><{$lang.position}><{$lang.level}></th>
        <th><{$lang.edit}></th>
        <th><{$lang.auth}></th>
        <th><{$lang.export}><{$lang.auth}></th>
        <th><{$lang.delete}></th>
    </tr>
    </thead>

    <tbody id="list"></tbody>

</table>

<div class="pagination"></div>

<div id="add" title="<{$lang.position}><{$lang.edit}>" style="display:none;">
    <div class="info">
        <div class="validateTips" id="tips"></div>
        <form id="createForm" name="createForm">
            <div class="item">
                <span class="userInfoLeft"><{$lang.position}><{$lang.name}>:</span>
                <span class="userInfoRight">
                    <input type="hidden" name="up_id"/>
                    <input type="text" name="up_name" id="up_name" class="text ui-widget-content "/>
                    <div class="errormsg"></div>
                </span>

                <div style="clear:both;"></div>
            </div>

            <div class="item">
                <span class="userInfoLeft"><{$lang.department}><{$lang.name}>:</span>
                <span class="text userInfoRight">
                    <select id="ud_id" name="ud_id" class="ui-widget-content">
                        <option value=''><{$lang.pls}></option>
                        <{foreach key=key item=item from=$departmentArr}>
                        <option value='<{$item.ud_id}>'><{$item.ud_name}></option>
                        <{/foreach}>
                    </select>
                    <div class="errormsg"></div>
                </span>

                <div style="clear: both;"></div>
            </div>

            <div class="item">
                <span class="userInfoLeft"><{$lang.position}><{$lang.level}>:</span>
                <span class="text userInfoRight">
                    <select id="up_level" name="up_level" class="ui-widget-content">
                        <option value=""><{$lang.pls}></option>
                        <option value="0">总经理</option>
                        <option value="1">总监</option>
                        <option value="2"><{$lang.department}>经理</option>
                        <option value="3">主管/组<{$lang.length}></option>
                        <option value="4">职员</option>
                    </select>
                    <div class="errormsg"></div>
                </span>

                <div style="clear: both;"></div>
            </div>
        </form>

    </div>
</div>